Are you sure you want to delete?

I accidentally deleted a chat conversation with a seller on OLX and it happened with no warning. Aargh!  Instead of making this a rant, I will talk about how to avoid such usability mistakes and empathize with the end users.

When you choose to delete something, the system verifies your choice by asking you to validate the decision. The purpose of validation is to ensure that the irreversible loss of information or data should not be of grave consequence for the user.
delete-validation
There are several instances in our daily digital lives that we end up deleting stuff. Emails immediately come to mind. Then, there are chat messages, SMSes, notifications, documents and many more.

On desktop OS, when we press delete after selecting a file, the system asks us to verify our decision to delete. But when we drag a file on a recycle bin, it does not. Why so? Its simple, you are making an effort to delete something by selecting it, dragging it to the destination and then releasing it on the recycle bin icon. You have to be pretty sure you want to delete to be doing that. On the other hand, the delete button can be accidentally pressed too. On top of it, even after you delete, you get one more chance to salvage the deleted item before you Empty out the recycle bin.

Safety Net
delete-undo
Irrespective of whether you verify a user action or not, you can always provide the user an option to revert his/her decision later. Even if the later is limited by time and not a permanent option.

 

delete-safety

Gmail provides options to Undo in multiple delete scenarios.

Snack-bar notifications allow us to communicate with the user the action applied as well as an alternative CTA to revert back the decision. The notification style is non obstructive in nature and hence will not leave any unpleasant experience when carrying out daily repetitive tasks.

This  brings us to the basic question, when do we validate?

  • Can the user invoke delete action accidentally? If yes, verify action.
  • Can the action be undone? If no, verify action.
  • Is the action repetitive (e.g removal of notifications)?
    • If its not critical, do not verify.
    • If you are not sure, give use a chance to undo it, but in a non obstructive manner. (like a snack bar notification with an option to ‘Undo’). These alternatives are like a limited time offer. J

So please, next time, have some empathy for the users and save them from the horror of accidental data loss.

Webviews : Quickly Building An App In HTML And More

Ever wondered how Amazon and Flipkart are able to churn on new App homescreen layouts so fast? The traditional app building approach would have meant having to push a update to users. But that means ensuring all users from your install base are updated to the new version. And also the headache of ensuring that the build is compatible with most of the devices in the mobile device ecosystem.  Its a nightmare!
Lets look at a few problem statements. You might have pondered on it at one point.

Case 1
You want to build an app in which you want the ability to add or remove screens, modify screen layout and/or change UI flow on need basis for the server side and reflecting on the existing app itself.

Case 2
You have a responsive website and want to engage even more with your users on mobile devices by developing an app. But you don’t have the budget (at least for now) or expertise to develop and full blow mobile app.

The solution
For the Android ecosystem, there exists, whats called, Android Webview. Its a system component powered by Chrome that allows Android apps to display web content. It comes pre-installed with the operating system. Webview allows 3rd party apps to show content in an in-app browser or in an app screen that pulls from the web. [sic].

For iOS ecosystem, there is UIWebview & WKWebview. Similarly, for other platforms there are different system components that allow for this hybrid form of integration.

Architecture of a webview
The below diagram compares and explains (quite well, actually) the difference between Native, Hybrid and Web Apps.
hybrid-native-web

courtesy of myShadesOfGray

Capability of webview
Modern webviews are quite powerful, both on Android and iOS platforms. What it means is that it can emulate an App like behavior without being glitchy. This includes behavior like –
Gesture support

Access to device camera, photographs etc

  • 60fps scroll support
  • Loading
  • History
  • Pagination
  • And More …

What all this means is that you can replicate an native app like behavior to UI created with HTML inside of your app. Your end user wouldn’t even know that the screen they are interacting with is actually a HTML page.

Webviews have come a long way from developing clunky UI to creating very smooth, performance driven and powerful applications.